<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
    <head>
        <title>SUHCK - Sistema Unificado Hospitalar de Controle Kabuloso </title>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        <meta name="title" content="Web site" />
        <meta name="description" content="Site description here" />
        <meta name="keywords" content="keywords here" />
        <meta name="language" content="en" />
        <meta name="subject" content="Site subject here" />
        <meta name="robots" content="All" />
        <meta name="copyright" content="Your company" />
        <meta name="abstract" content="Site description here" />
        <meta name="MSSmartTagsPreventParsing" content="true" />
        <link id="theme" rel="stylesheet" type="text/css" href="style.css" title="theme" />
        <script src="jQueryAssets/jquery-1.8.3.min.js" type="text/javascript"></script>
        <script src="jQueryAssets/jquery-ui-1.9.2.tabs.custom.min.js" type="text/javascript"></script><script src="jQueryAssets/jquery-ui-1.9.2.button.custom.min.js" type="text/javascript"></script>
        <link rel="stylesheet" href="js/jquery-ui-1.11.2/jquery-ui.structure.css">
            <link href="jQueryAssets/jquery.ui.core.min.css" rel="stylesheet" type="text/css" />
            <link href="jQueryAssets/jquery.ui.theme.min.css" rel="stylesheet" type="text/css" />
            <link href="jQueryAssets/jquery.ui.tabs.min.css" rel="stylesheet" type="text/css" />
            <link href="jQueryAssets/jquery.ui.button.min.css" rel="stylesheet" type="text/css" />
    </head>
    <body> 
        <div id="wrapper"> 
            <div id="bg"> 
                <div id="header"></div>  
                <div id="page"> 
                    <div id="container"> 
                        <!-- banner -->  
                        <div id="banner"></div>  
                        <!-- end banner -->  
                        <!-- horizontal navigation -->  
                        <div id="nav1"> 
                            <ul>
                                <li>
                                    <a href="InicioAtendente.jsp" shape="rect">Pagina Inicial</a>
                                </li>
                                <li>
                                    <a href="Front?action=listarPaciente">Voltar </a>
                                </li>
                                <li> <blockquote></blockquote></li>
                                <li> <blockquote></blockquote></li>
                                <li> <blockquote></blockquote></li>
                                <li> <blockquote></blockquote></li>


                                <li> <blockquote></blockquote></li>
                                <li>
                                    <a href="Front?action=logout">Sair </a>
                                </li>
                            </ul> 
                        </div> 
                        <!-- end horizontal navigation -->  
                        <!--  content -->  
                        <div id="content">
                            <div id="center"> 
                                <div id="welcome"> 
                                    <h2>PAINEL ATENDENTE - Alterar Paciente</h2><br />

                                    <form  action="Front" method="POST">

                                        <input type="hidden" name="idpaciente" value="${paciente.id}" /><br>
                                            <input type="hidden" name="idpacienteplano" value="${paciente.pacientePlano.id}" /><br>        

                                                <label>Nome: </label>
                                                <input type="text" required name="nome" value="${paciente.nome}" size="35"/> 
                                                <label>CPF: </label>
                                                <input type="text" required name="cpf" value="${paciente.cpf}" size="20" /><br /><br /><br />
                                                <label>Endereco Completo: </label>
                                                <input type="text" required name="enderecocompleto" value="${paciente.endereco}" size="53"/><br /><br /><br />
                                                <label>E-mail: </label>
                                                <input type="text" required name="email" value="${paciente.email}" size="35"/>
                                                <label>Telefone: </label>
                                                <input type="text" required name="telefone" value="${paciente.telefone}" size="18"/><br /><br /><br />
                                                <label> </label><label for="select">Plano de Saude ${planoSelecionado}:</label>
                                                <select name="plano">
                                                    <c:forEach items="${planos}" var="planosaude"> 
                                                        <c:choose>
                                                            <c:when test="${planosaude.id == planoSelecionado}">
                                                                <option selected value="${planosaude.id}">${planosaude.nome}</option>
                                                            </c:when>
                                                            <c:otherwise>
                                                                <option value="${planosaude.id}">${planosaude.nome}</option>
                                                            </c:otherwise>
                                                        </c:choose>

                                                    </c:forEach>    
                                                </select>                      
                                                <label>Número:</label>
                                                <input type="text" required name="numero" value="${paciente.pacientePlano.numero}" size="18"/> <br><br /><br />
                                                    <label> </label>
                                                    <label>Tipo:</label>
                                                    <input type="text" required name="tipo" value="${paciente.pacientePlano.tipo}" size="35"/> 
                                                    <input type="hidden" name="action" value="alterarPaciente" /><br><br />

                                                        <input type="submit" class="btn" value="Salvar" />
                                                        </form>     


                                                        </div>
                                                        </div>
                                                        </div>
                                                        <div class="clear" style="height:40px"></div> 
                                                        </div>  
                                                        <!-- end content --> 
                                                        </div>  
                                                        <!-- end container --> 
                                                        </div>  
                                                        <div id="footerWrapper"> 
                                                            <div id="footer"> 
                                                                <p style="padding-top:10px"> 
                                                                </p> 
                                                            </div> 
                                                        </div> 
                                                        </div> 
                                                        </div>
                                                        <script type="text/javascript">
                                                            $(function () {
                                                                $("#Button1").button();
                                                            });
                                                            $(function () {
                                                                $("#Tabs1").tabs({
                                                                    heightStyle: "content"
                                                                });
                                                            });
                                                            $(function () {
                                                                $("#Checkboxes1").buttonset();
                                                            });
                                                        </script>
                                                        </body>
                                                        </html>
